package sis.ra.yahoor.result;

import sis.ra.utility.Utils;

public class extractVerbPattern {

	/**
	 * @pbe	288
launch	176
announce	141
acquire	102
have	101
release	89
buy	77
say	58
add	49
use	48
offer	39

	 */
	public static void main(String[] args) {
		String verbfile="C:\\Documents and Settings\\I820753\\Desktop\\dataset\\result1006.verbv";
		String content=Utils.readFile(verbfile);
		String [] lines=content.split("\n");
		int count=0;
		for (int i=0;i<lines.length;i++)
		{
			if (lines[i].split("\t").length<2) continue;
	//		System.out.println(lines[i]);
			String verbterm=lines[i].split("\t")[1];
//			if (lines[i].contains("buy")||lines[i].contains("bought"))
//			{
			if (verbterm.contains("buy")||verbterm.contains("bought"))
			{
				System.out.println(lines[i]);
				count=count+1;
				Utils.writeFile("C:\\Documents and Settings\\I820753\\Desktop\\dataset\\buy.result1006", lines[i]);
			}
		}
		System.out.println(count);
	}

}
